<?php

namespace App\Models\Factory;


use App\Models\AbsModelFactory;
use App\Models\Orm\Safety;


/**
 * 意见反馈工厂
 * Class FeedbackFactory
 * @package App\Models\Factory
 */
class SafetyFactory extends AbsModelFactory
{

    //获取托管时间
    public static  function getSecure($userId)
    {
        $result = Safety::where('uid',$userId)->first();
        return $result ? $result : '';
    }

    //修改最后到期时间
    public static  function updateLassTime($userId,$data)
    {
        $result = Safety::where('uid',$userId)->update($data);
        return $result ? true :false;
    }
}